package com.yangkun.model;


import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class Result <T> {

    private Integer code = 200;
    private String msg;
    private T data;


    public static <T> Result <T> success(String msg , T data){
        Result result = new Result();
        result.setMsg(msg);
        result.setData(data);
        return result;
    }
 }
